export const getSum = arr => arr.reduce((sum, val) => sum += val)
console.log((getSum([1, 2, 3, 4, 5, 6])));